package com.bsoft.exchange.dao.his;


import com.bsoft.exchange.domain.GY_SHDDHDomain;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;



@Mapper
public interface CreateOrderNoMapper {
	
	/**
	 * 获取病人id
	 */
	Integer getBrid(@Param("zjlx")int zjlx,@Param("zjhm")String zjhm, @Param("jgid")int jgid);
	/**
	 * 插入商户订单
	 */
	Integer insertShddh(@Param("shddh")String shddh,@Param("ywlb")String ywlb,@Param("brid")int brid,@Param("czsj")Date czsj,@Param("zfje")Double zfje,@Param("zffs")int zffs,@Param("jgid")int jgid) ;
	/**
	 * 更新商户订单业务状态
	 */
	Integer updateShddhYwzt(@Param("shddh")String shddh,@Param("ywzt")int ywzt,@Param("jgid")int jgid) ;
	/**
	 * 更新商户订单支付状态
	 */
	Integer updateShddhZfzt(@Param("shddh")String shddh,@Param("zfzt")int zfzt,@Param("zfsj")Date zfsj,@Param("zffs")int zffs,
							@Param("jgid")int jgid,@Param("jylsh")String jylsh,@Param("fphm")String fphm) ;
	
	public GY_SHDDHDomain getShddhById(@Param("shddh")String shddh, @Param("jgid")Long jgid);


	public GY_SHDDHDomain getShddhByFphm(@Param("fphm")String fphm, @Param("jgid")Long jgid, @Param("ywlb")Integer ywlb);
	/**
	 * 插入商户订单
	 */
	Integer insertShddhAll(@Param("shddh")String shddh,@Param("ywlb")int ywlb,@Param("brid")int brid,
						   @Param("czsj")Date czsj,@Param("zfje")Double zfje,@Param("zffs")int zffs,
						   @Param("jgid")int jgid,@Param("ywzt")int ywzt,@Param("zfzt")int zfzt,
						   @Param("jylsh")String jylsh,@Param("fphm")String fphm) ;
}
